<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>超级管理员界面</title>
		<link rel="stylesheet" type="text/css" href="easyui/themes/default/easyui.css" />
		<link rel="stylesheet" type="text/css" href="easyui/themes/icon.css">
		<link rel="stylesheet" type="text/css" href="easyui/themes/wu.css" />
		<script type="text/javascript" src="easyui/jquery.min.js"></script>
		<script type="text/javascript" src="easyui/jquery.easyui.min.js"></script>
		<script type="text/javascript" src="easyui/locale/easyui-lang-zh_CN.js"></script>
	</head>
	<script type="text/javascript">
		function logout(){
			if(confirm("您确定要退出登录吗？")){
						window.location.href="login.html";
			}
			return false;
		}
	</script>
	<body class="easyui-layout">

		<!--顶部-->
	    <div data-options="region:'north',split:true"  style="height:80px;background: black">
		    	<div class="wu-header-left">
	        	<h1>葡萄种质资源数据管理系统</h1>
	        	</div>
		        <div class="wu-header-right">
		            <p><a href="#">网站首页</a>|<a href="#">支持论坛</a>|<a href="#">帮助中心</a>|<a href="javascript:void(0)" onclick="logout()">安全退出</a></p>
		        </div>
	    </div>
	    <!--底部-->
	    <div data-options="region:'south',title:'South Title',split:true" style="height:100px;">
	    	
	    </div>-->
	    <!--左侧菜单栏-->
	    <div data-options="region:'west',title:'导航菜单',split:true" style="width:150px;">
	    	<div class="easyui-accordion" data-options="fit:true,border:false">
				<div title="快捷菜单" data-options="iconCls:'icon-application-cascade'" style="padding:5px;">
					<ul class="easyui-tree wu-side-tree">
						<li iconCls="icon-chart-organisation"><a href="javascript:void(0)" data-icon="icon-chart-organisation" iframe="1" data-link="putao_zyj.html" >资源结实力评价</a></li>
						<li iconCls="icon-users"><a href="javascript:void(0)" data-icon="icon-users"  data-link="users.html" iframe="1">用户管理</a></li>
						<li iconCls="icon-book"><a href="javascript:void(0)" data-icon="icon-book" data-link="putao_zygsxz.html" iframe="1">资源果实性状评价</a></li>
						<li iconCls="icon-chart-organisation"><a href="javascript:void(0)" data-icon="icon-chart-organisation" iframe="1" data-link="putao_kinds.html" >葡萄品种管理</a></li>
						<li iconCls="icon-chart-organisation"><a href="javascript:void(0)" data-icon="icon-chart-organisation" iframe="1" data-link="putao_gspzxz.html" >果实品质性状鉴定</a></li>
						<li iconCls="icon-book"><a href="javascript:void(0)" data-icon="icon-book" data-link="msb.html" iframe="1">霜霉病感病的差异鉴定</a></li>
					</ul>
				</div>
			</div>
	    </div>
	    <div data-options="region:'center',border:false," style="padding:0px;">
	    	<div id="tabs"   class="easyui-tabs" data-options="fit:true"  style="width:500px;height:250px;">
   					 <div title="首页" style="padding:20px;display:none;">
						<img src="img/葡萄.jpg" width="100%" height="100%">
    				</div>
			</div>
	    </div>
	    <script type="text/javascript">
			$(function () {
				$('.wu-side-tree a').bind("click",function () {
					var title = $(this).text();
					var url=$(this).attr('data-link');
					var iconCls=$(this).attr('data-icon');
					var iframe=$(this).attr('iframe')==1?true:false;
					addTab(title,url,iconCls,iframe);
				})
			});
			/*
			载入树形菜单
			*/
			$('#wu-side-tree').tree({
				url:'home2.html',
				cache:false,
				onClick:function (node) {
					var url=node.attributes['url'];
					if(url==null||url==""){
						return false;
					}else {
						addTab(node.text,url,'',node.attributes['iframe']);
					}

				}
			});
			/*
			Name 选型卡初始化
			 */
	    	$("#tabs").tabs({
				tools:[{
					iconCls:'icon-reload',
					border:false,
					handler:function () {
						$('#dg').datagrid('reload');
					}
				}]
			});

			/*
			 *Name 添加菜单选项
			 * Param title 名称
			 * Param href 链接
			 * Param iconCls 图标样式
			 * Param iframe 链接跳转方式（true 为iframe false 为 href）
			 */
			function addTab(title,href,iconCls,iframe) {
				var tabPanel=$('#tabs');
				if(!tabPanel.tabs('exists',title)){
					var content ='<iframe scrolling="auto" frameborder="0" src="'+href+'" style="width: 100% ;height: 100%"></iframe>';
					if(iframe){
						tabPanel.tabs('add',{
							title:title,
							content:content,
							iconCls:iconCls,
							fit:true,
							cls:'pd3',
							closable:true
						});
					}else{
						tabPanel.tabs('add',{
							title:title,
							href:href,
							iconCls:iconCls,
							fit:true,
							cls:'pd3',
							closable:true
						})
					}
				}else {
					tabPanel.tabs('select',title);
				}
			}
			/*
			Name移除菜单选型
			 */
			function removeTab() {
				var tabPanel=$("#tabs");
				var tab = tabPanel.tabs("getSelected");
				if(tab){
					var index=tabPanel.tabs('getTabindex',tab);
					tabPanel.tabs('close',index);
				}
			}/*
			单个添加功能
			function goTabs1(){
				var tabs = $("#tt");
				var tab = tabs.tabs("getTab",'数据管理');
				if(tab){
					alert("已经有此选项卡");//如果面板中有这个选项卡，则选中该选项卡
				}else{
					tabs.tabs("add",{              //如果面板中没有改选项卡，就添加一个选项卡add方法
						title: '数据管理',
						content: '<iframe src="putao_zygsxz.html" width="100%" height="100%"></iframe>',
						closable: true

					})
				}
			}*/
		</script>
	</body>
</html>
